import Vue from 'vue'
import App from './App.vue'
import router from './router'
import store from './store'
// 定时任务，每天
const schedule = require('node-schedule');
// 设定规则
let rule = new schedule.RecurrenceRule();
// 每天 12 点更新数据
rule.hour =0;
rule.minute =0;
rule.second =0;

import _ from 'lodash' 
import 'echarts/lib/chart/map'
import 'echarts/lib/chart/line'
import 'echarts/lib/component/visualMap'
import 'echarts/map/js/world'
import './styles/init.styl'

import getData from './build-data'
// 启动任务
schedule.scheduleJob(rule, () => {
  getData()
})

Vue.prototype._ = _

Vue.config.productionTip = false

new Vue({
  router,
  store,
  render: h => h(App)
}).$mount('#app')
